<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: lsy
  Date: 2020/12/30
  Time: 10:35
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>修改</title>
</head>
<body>
<form action="${pageContext.request.contextPath}/peitems/update.do" method="post">
    <input type="hidden" name="itemid" id="itemid" value="${pr[0]}">
    <table align="center" border="1" width="800px" height="900px">
        <tr align="center">
            <td colspan="2"><h2>修改好友信息 ${param.itemid}</h2></td>
        </tr>
        <tr align="center">
            <td>项目名称:</td>
            <td>
                <input type="text" id="itemname" name="itemname" value="${pr[1]}">
                <span style="color: red;"></span>
            </td>
        </tr>
        <tr align="center">
            <td>项目类别:</td>
            <td>
                <select name="typeid">
                    <c:choose>
                        <c:when test="${pr[2] == 1}">
                            <option value="1" >老师</option>
                            <option value="2">同学</option>
                        </c:when>
                        <c:when test="${pr[2] == 2}">
                            <option value="1" >老师</option>
                            <option value="2" >同学</option>
                        </c:when>
                    </c:choose>
                </select>
            </td>
        </tr>
        <tr align="center">
            <td>是否必查:</td>
            <td>
                <select name="necessary">
                    <c:choose>
                        <c:when test="${pr[3] == 1}">
                            <option value="1" selected>是</option>
                            <option value="2">否</option>
                        </c:when>
                        <c:when test="${pr[3] == 2}">
                            <option value="1" >是</option>
                            <option value="2" selected>否</option>
                        </c:when>
                    </c:choose>
                </select>
            </td>
        </tr>
        <tr align="center">
            <td>参考值</td>
            <td>
                <input type="text" name="ref" value="${pr[4]}">
            </td>
        </tr>
        <tr align="center">
        <td>价格</td>
        <td>
            <input type="text" name="price" value="${pr[5]}">
        </td>
    </tr>
        <tr align="center">
        <td>说明</td>
        <td>
            <input type="text" name="info" value="${pr[6]}">
        </td>
    </tr>
        <tr align="center">
            <td colspan="2">
                <input type="submit" value="保存">
            </td>
        </tr>
    </table>
</form>
<input type="hidden" id="path" value="${pageContext.request.contextPath}">

<script type="text/javascript" src="${pageContext.request.contextPath}/static/js/common.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/static/js/jquery-1.8.3.min.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/static/js/upd.js"></script>
</body>
</html>
